import $api from '.';

interface User {
  uname: string;
  password: string;
}

export const userLogin = function (data: User) {
  return $api.post('/authentication', {
    strategy: 'local',
    ...data,
  });
};

export const updateUserInfo = function (userid: number, data: any) {
  return $api.patch(`/users/${userid}`, data);
};

export default {};
